// 题目路由
const article = require('express').Router()

// 题目创建
article.post('/add', require('./action/article/admin_add'))

// 根据id查询题目
article.get('/:id', require('./action/article/findById'))

// 题目查询
article.get('/', require('./action/article/admin_find'))

// 编辑题目后提交
article.put('/edit/:id', require('./action/article/editById'))

// 根据id删除题目
article.delete('/delete/:id', require('./action/article/deleteById'))

// 根据id更新审核状态
article.put('/check/:id', require('./action/article/update_check'))

// 根据老师id查询题目
article.get('/teacher/:id', require('./action/article/findByTeacherId'))

module.exports = article